<?php
session_start();
@mysql_connect('localhost', 'root', 'root');
mysql_select_db('blog');
mysql_set_charset('utf8');
$sqla = "select * from `lanmu`";
$resa = mysql_query($sqla);
while ($rowsa = mysql_fetch_assoc($resa)) {
    $arra[] = $rowsa;
}
?>
<!doctype html>
<html>
<head>
<meta charset="utf8">
<title>个人博客</title>
<meta name="keywords" content="个人博客模板古典系列之——江南墨卷" />
<meta name="description" content="个人博客模板古典系列之——江南墨卷" />
<link href="/home/public/css/base.css" rel="stylesheet">
<link href="/home/public/css/index.css" rel="stylesheet">
<!--[if lt IE 9]>
<script src="js/modernizr.js"></script>
<![endif]-->
<script type="text/javascript" src="/home/public/js/jquery.js"></script>
</head>
<body>
<div class="topnav">
<p align="right"><i style="color: red "><?php echo isset($_SESSION['uname']) ?"欢迎回来". $_SESSION['uname'] : ''; ?></i><a href="/admin/login/login.php">管理员</a><a href="login/login.php">登录</a> <a href="login/zhuce.php">注册</a></p>


</div>
<div id="wrapper">
  <header>
    <div class="headtop"></div>
    <div class="contenttop">
      <div class="logo f_l">个人博客</div>
      <!-- <div class="search f_r">
        <form action="../index.php" method="get" name="keywords" id="searchform">
          <input name="keywords" id="keyboard" class="input_text" value="请输入关键字" style="color: rgb(153, 153, 153);" onfocus="if(value=='请输入关键字'){this.style.color='#000';value=''}" onblur="if(value==''){this.style.color='#999';value='请输入关键字'}" type="text">

          <input name="Submit" class="input_submit" value="搜索" type="submit">
        </form>
      </div> -->
      <div class="blank"></div>
      <nav>
        <div  class="navigation">
          <ul class="menu">
            <li><a href="index.php">网站首页</a></li>
            <li><a href="about.php">关于我</a>
              <ul>
                <li><a href="about.php">个人简介</a></li>
                <li><a href="listpic.php">个人相册</a></li>
              </ul>
            </li>
            <li><a href="index.php">文章类别</a>
              <ul>
              <?php
                  foreach ($arra as $v) {
                      echo '<li><a href="../home/index.php?fenlei=' . $v['name'] . '">' . $v['name'] . '</a></li>';
                  }
                  ?>
              </ul>
            </li>
           <!--  <li><a href="newslistpic.php">技术文章</a> </li> -->
            <li><a href="message.php">给我留言</a> </li>
          </ul>
        </div>
      </nav>
      <SCRIPT type=text/javascript>
  // Navigation Menu
  $(function() {
    $(".menu ul").css({display: "none"}); // Opera Fix
    $(".menu li").hover(function(){
      $(this).find('ul:first').css({visibility: "visible",display: "none"}).slideDown("normal");
    },function(){
      $(this).find('ul:first').css({visibility: "hidden"});
    });
  });
</SCRIPT>
    </div>
  </header>